﻿<s:SurfaceWindow x:Class="MediaSurface.SurfaceWindow1"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:s="http://schemas.microsoft.com/surface/2008"
    Title="MediaSurface" Background="CadetBlue"
    xmlns:local="clr-namespace:MediaSurface"
    >
  <s:SurfaceWindow.Resources>
    <ImageBrush x:Key="WindowBackground" Stretch="Fill" Opacity="1" ImageSource="pack://application:,,,/Resources/Background.jpg
                "/>

        <Style x:Key="LibraryControlInScatterViewItemContentStyle" TargetType="{x:Type s:ScatterViewItem}">
            <Setter Property="MinWidth" Value="{Binding Path=Content.MinWidth, RelativeSource={RelativeSource Self}, Mode=OneWay}"/>
            <Setter Property="MinHeight" Value="{Binding Path=Content.MinHeight, RelativeSource={RelativeSource Self}, Mode=OneWay}"/>
            <Setter Property="MaxWidth" Value="{Binding Path=Content.MaxWidth, RelativeSource={RelativeSource Self}, Mode=OneWay}"/>
            <Setter Property="MaxHeight" Value="{Binding Path=Content.MaxHeight, RelativeSource={RelativeSource Self}, Mode=OneWay}"/>
            <Setter Property="IsActive" Value="{Binding Path=Content.IsActive,RelativeSource={RelativeSource Self}, Mode=OneWayToSource}"/>
            <Setter Property="Width" Value="{Binding Path=Content.Width, RelativeSource={RelativeSource Self}, Mode=TwoWay}"/>
            <Setter Property="Height" Value="{Binding Path=Content.Height, RelativeSource={RelativeSource Self}, Mode=TwoWay}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type s:ScatterViewItem}">
                        <ContentPresenter />
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>

        <Style x:Key="BarItemStyle" TargetType="{x:Type s:LibraryBarItem}">
            <Style.Triggers>
                <Trigger Property="s:LibraryBarItem.IsItemDataEnabled" Value="False">
                    <Setter Property="s:LibraryBarItem.Padding" Value="5"/>
                    <Setter Property="s:LibraryBarItem.Background" Value="Blue"/>
                </Trigger>
            </Style.Triggers>
        </Style>
    </s:SurfaceWindow.Resources>

    
  <Grid Name="mainGrid" Background="{StaticResource WindowBackground}" >
         
        <s:ScatterView Name="scatterView1"  Background="Transparent" AllowDrop="True" s:SurfaceDragDrop.Drop="scatterView1_Drop">
       
            <s:ScatterViewItem Background="Transparent" Name="libraryBarSuper" Style="{StaticResource LibraryControlInScatterViewItemContentStyle}" 
                                     Orientation="0.0" Center="200,200"  AllowDrop="False" DecelerationRate="4500" AngularDecelerationRate="1200">
                   
                        
            </s:ScatterViewItem>

       
        </s:ScatterView>
      
    </Grid>
</s:SurfaceWindow>
